<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.11"/>
<title>Kinetis Bootloader Host: IVTDataSource.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="nxp_logo_small.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Kinetis Bootloader Host
   &#160;<span id="projectnumber">2.0.0</span>
   </div>
   <div id="projectbrief">Host Tools for Kinetis devices</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Introduction</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('_i_v_t_data_source_8h_source.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">IVTDataSource.h</div>  </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/*</span></div><div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment"> * File:    DataSource.h</span></div><div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"> * Copyright (c) Freescale Semiconductor, Inc. All rights reserved.</span></div><div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="comment"> * Freescale Semiconductor, Inc.</span></div><div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="comment"> * Proprietary &amp; Confidential</span></div><div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="comment"> * This source code and the algorithms implemented therein constitute</span></div><div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="comment"> * confidential information and may comprise trade secrets of Freescale Semiconductor, Inc.</span></div><div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="comment"> * or its associates, and any use thereof is subject to the terms and</span></div><div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment"> * conditions of the Confidential Disclosure Agreement pursual to which this</span></div><div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment"> * source code was originally received.</span></div><div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment"> */</span></div><div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="preprocessor">#if !defined(_IVTDataSource_h_)</span></div><div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="preprocessor">#define _IVTDataSource_h_</span></div><div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;</div><div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="preprocessor">#include &quot;DataSource.h&quot;</span></div><div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;</div><div class="line"><a name="l00023"></a><span class="lineno"><a class="line" href="structhab__hdr__t.html">   23</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>hab_hdr</div><div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;{</div><div class="line"><a name="l00025"></a><span class="lineno"><a class="line" href="structhab__hdr__t.html#ad7913394bcc1cc055f23c71d6a8cf875">   25</a></span>&#160;    uint8_t <a class="code" href="structhab__hdr__t.html#ad7913394bcc1cc055f23c71d6a8cf875">tag</a>;    </div><div class="line"><a name="l00026"></a><span class="lineno"><a class="line" href="structhab__hdr__t.html#a1bbbde06a576c8402b1865a98eaa5fb0">   26</a></span>&#160;    uint8_t len[2]; </div><div class="line"><a name="l00027"></a><span class="lineno"><a class="line" href="structhab__hdr__t.html#aa93cdf5874f6a16f0d84e7a0eaaf43d9">   27</a></span>&#160;    uint8_t <a class="code" href="structhab__hdr__t.html#aa93cdf5874f6a16f0d84e7a0eaaf43d9">par</a>;    </div><div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;} <a class="code" href="structhab__hdr__t.html">hab_hdr_t</a>;</div><div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;</div><div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;<span class="keyword">typedef</span> void (*hab_image_entry_f)(void);</div><div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;</div><div class="line"><a name="l00091"></a><span class="lineno"><a class="line" href="structhab__ivt.html">   91</a></span>&#160;<span class="keyword">struct </span><a class="code" href="structhab__ivt.html">hab_ivt</a></div><div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;{</div><div class="line"><a name="l00096"></a><span class="lineno"><a class="line" href="structhab__ivt.html#a1b7fc9e9d52309f56b57a9543349bf00">   96</a></span>&#160;    <a class="code" href="structhab__hdr__t.html">hab_hdr_t</a> <a class="code" href="structhab__ivt.html#a1b7fc9e9d52309f56b57a9543349bf00">hdr</a>;</div><div class="line"><a name="l00100"></a><span class="lineno"><a class="line" href="structhab__ivt.html#afc055b3b0f6aa49f14f48333bf331982">  100</a></span>&#160;    <span class="comment">/*hab_image_entry_f*/</span> uint32_t <a class="code" href="structhab__ivt.html#afc055b3b0f6aa49f14f48333bf331982">entry</a>;</div><div class="line"><a name="l00102"></a><span class="lineno"><a class="line" href="structhab__ivt.html#a6b496edf283c9d3b3b2397e6fd4a8db7">  102</a></span>&#160;    <span class="comment">/*const void*/</span> uint32_t <a class="code" href="structhab__ivt.html#a6b496edf283c9d3b3b2397e6fd4a8db7">reserved1</a>;</div><div class="line"><a name="l00104"></a><span class="lineno"><a class="line" href="structhab__ivt.html#af15467ad5c571cb1989439c412b85a71">  104</a></span>&#160;    <span class="comment">/*const void*/</span> uint32_t <a class="code" href="structhab__ivt.html#af15467ad5c571cb1989439c412b85a71">dcd</a>;</div><div class="line"><a name="l00108"></a><span class="lineno"><a class="line" href="structhab__ivt.html#ad7d705aa6b9f376da4b45dc2aee99112">  108</a></span>&#160;    <span class="comment">/*const void*/</span> uint32_t <a class="code" href="structhab__ivt.html#ad7d705aa6b9f376da4b45dc2aee99112">boot_data</a>;</div><div class="line"><a name="l00110"></a><span class="lineno"><a class="line" href="structhab__ivt.html#a38ad470926876c372e91f4212360338d">  110</a></span>&#160;    <span class="comment">/*const void*/</span> uint32_t <span class="keyword">self</span>;</div><div class="line"><a name="l00112"></a><span class="lineno"><a class="line" href="structhab__ivt.html#a117eb7ff63a99d084b07d2fcce5ff1f1">  112</a></span>&#160;    <span class="comment">/*const void*/</span> uint32_t <a class="code" href="structhab__ivt.html#a117eb7ff63a99d084b07d2fcce5ff1f1">csf</a>;</div><div class="line"><a name="l00114"></a><span class="lineno"><a class="line" href="structhab__ivt.html#a2c8ce15b7dd410f382d19515d51d471e">  114</a></span>&#160;    uint32_t <a class="code" href="structhab__ivt.html#a2c8ce15b7dd410f382d19515d51d471e">reserved2</a>;</div><div class="line"><a name="l00115"></a><span class="lineno">  115</span>&#160;};</div><div class="line"><a name="l00116"></a><span class="lineno">  116</span>&#160;</div><div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span><a class="code" href="structhab__ivt.html">hab_ivt</a> hab_ivt_t;</div><div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160;</div><div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;<span class="comment">/*</span></div><div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160;<span class="comment"> *    Helper macros</span></div><div class="line"><a name="l00124"></a><span class="lineno">  124</span>&#160;<span class="comment"> */</span></div><div class="line"><a name="l00125"></a><span class="lineno">  125</span>&#160;<span class="preprocessor">#define HAB_CMD_UNS 0xff</span></div><div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;</div><div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;<span class="preprocessor">#define DEFAULT_IMG_KEY_IDX 2</span></div><div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;</div><div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;<span class="preprocessor">#define GEN_MASK(width) ((1UL &lt;&lt; (width)) - 1)</span></div><div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;</div><div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;<span class="preprocessor">#define GEN_FIELD(f, width, shift) (((f)&amp;GEN_MASK(width)) &lt;&lt; (shift))</span></div><div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;</div><div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160;<span class="preprocessor">#define PACK_UINT32(a, b, c, d) ((((a)&amp;0xFF) &lt;&lt; 24) | (((b)&amp;0xFF) &lt;&lt; 16) | (((c)&amp;0xFF) &lt;&lt; 8) | (((d)&amp;0xFF)))</span></div><div class="line"><a name="l00134"></a><span class="lineno">  134</span>&#160;</div><div class="line"><a name="l00135"></a><span class="lineno">  135</span>&#160;<span class="preprocessor">#define EXPAND_UINT32(w) (uint8_t)((w) &gt;&gt; 24), (uint8_t)((w) &gt;&gt; 16), (uint8_t)((w) &gt;&gt; 8), (uint8_t)(w)</span></div><div class="line"><a name="l00136"></a><span class="lineno">  136</span>&#160;</div><div class="line"><a name="l00137"></a><span class="lineno">  137</span>&#160;<span class="preprocessor">#define HDR(tag, bytes, par) (uint8_t)(tag), (uint8_t)((bytes) &gt;&gt; 8), (uint8_t)(bytes), (uint8_t)(par)</span></div><div class="line"><a name="l00138"></a><span class="lineno">  138</span>&#160;</div><div class="line"><a name="l00139"></a><span class="lineno">  139</span>&#160;<span class="preprocessor">#define HAB_VER(maj, min) \</span></div><div class="line"><a name="l00140"></a><span class="lineno">  140</span>&#160;<span class="preprocessor">    (GEN_FIELD((maj), HAB_VER_MAJ_WIDTH, HAB_VER_MAJ_SHIFT) | GEN_FIELD((min), HAB_VER_MIN_WIDTH, HAB_VER_MIN_SHIFT))</span></div><div class="line"><a name="l00141"></a><span class="lineno">  141</span>&#160;</div><div class="line"><a name="l00142"></a><span class="lineno">  142</span>&#160;<span class="comment">/*</span></div><div class="line"><a name="l00143"></a><span class="lineno">  143</span>&#160;<span class="comment"> *    CSF header</span></div><div class="line"><a name="l00144"></a><span class="lineno">  144</span>&#160;<span class="comment"> */</span></div><div class="line"><a name="l00145"></a><span class="lineno">  145</span>&#160;</div><div class="line"><a name="l00146"></a><span class="lineno">  146</span>&#160;<span class="preprocessor">#define CSF_HDR(bytes, HABVER) HDR(HAB_TAG_CSF, (bytes), HABVER)</span></div><div class="line"><a name="l00147"></a><span class="lineno">  147</span>&#160;</div><div class="line"><a name="l00148"></a><span class="lineno">  148</span>&#160;<span class="comment">/*</span></div><div class="line"><a name="l00149"></a><span class="lineno">  149</span>&#160;<span class="comment"> *    DCD  header</span></div><div class="line"><a name="l00150"></a><span class="lineno">  150</span>&#160;<span class="comment"> */</span></div><div class="line"><a name="l00151"></a><span class="lineno">  151</span>&#160;</div><div class="line"><a name="l00152"></a><span class="lineno">  152</span>&#160;<span class="preprocessor">#define DCD_HDR(bytes, HABVER) HDR(HAB_TAG_DCD, (bytes), HABVER)</span></div><div class="line"><a name="l00153"></a><span class="lineno">  153</span>&#160;</div><div class="line"><a name="l00154"></a><span class="lineno">  154</span>&#160;<span class="comment">/*</span></div><div class="line"><a name="l00155"></a><span class="lineno">  155</span>&#160;<span class="comment"> *   IVT  header (goes in the struct&#39;s hab_hdr_t field, not a byte array)</span></div><div class="line"><a name="l00156"></a><span class="lineno">  156</span>&#160;<span class="comment"> */</span></div><div class="line"><a name="l00157"></a><span class="lineno">  157</span>&#160;<span class="preprocessor">#define IVT_HDR(bytes, HABVER)                                             \</span></div><div class="line"><a name="l00158"></a><span class="lineno">  158</span>&#160;<span class="preprocessor">    {                                                                      \</span></div><div class="line"><a name="l00159"></a><span class="lineno">  159</span>&#160;<span class="preprocessor">        HAB_TAG_IVT, { (uint8_t)((bytes) &gt;&gt; 8), (uint8_t)(bytes) }, HABVER \</span></div><div class="line"><a name="l00160"></a><span class="lineno">  160</span>&#160;<span class="preprocessor">    }</span></div><div class="line"><a name="l00161"></a><span class="lineno">  161</span>&#160;</div><div class="line"><a name="l00169"></a><span class="lineno">  169</span>&#160;<span class="preprocessor">#define HAB_TAG_IVT 0xd1 </span></div><div class="line"><a name="l00170"></a><span class="lineno">  170</span>&#160;<span class="preprocessor">#define HAB_TAG_DCD 0xd2 </span></div><div class="line"><a name="l00171"></a><span class="lineno">  171</span>&#160;<span class="preprocessor">#define HAB_TAG_CSF 0xd4 </span></div><div class="line"><a name="l00172"></a><span class="lineno">  172</span>&#160;<span class="preprocessor">#define HAB_TAG_CRT 0xd7 </span></div><div class="line"><a name="l00173"></a><span class="lineno">  173</span>&#160;<span class="preprocessor">#define HAB_TAG_SIG 0xd8 </span></div><div class="line"><a name="l00174"></a><span class="lineno">  174</span>&#160;<span class="preprocessor">#define HAB_TAG_EVT 0xdb </span></div><div class="line"><a name="l00175"></a><span class="lineno">  175</span>&#160;<span class="preprocessor">#define HAB_TAG_RVT 0xdd </span></div><div class="line"><a name="l00176"></a><span class="lineno">  176</span>&#160;<span class="preprocessor">                         </span><span class="comment">/* Values b0 ... cf reserved for CSF commands.  Values e0 ... ef reserved for</span></div><div class="line"><a name="l00177"></a><span class="lineno">  177</span>&#160;<span class="comment">                          * key types.</span></div><div class="line"><a name="l00178"></a><span class="lineno">  178</span>&#160;<span class="comment">                          *</span></div><div class="line"><a name="l00179"></a><span class="lineno">  179</span>&#160;<span class="comment">                          * Available values: 03, 05, 06, 09, 0a, 0c, 0f, 11, 12, 14, 17, 18, 1b, 1d,</span></div><div class="line"><a name="l00180"></a><span class="lineno">  180</span>&#160;<span class="comment">                          * 1e, 21, 22, 24, 27, 28, 2b, 2d, 2e, 30, 33, 35, 36, 39, 3a, 3c, 3f, 41, 42,</span></div><div class="line"><a name="l00181"></a><span class="lineno">  181</span>&#160;<span class="comment">                          * 44, 47, 48, 4b, 4d, 4e, 50, 53, 55, 56, 59, 5a, 5c, 5f, 60, 63, 65, 66, 69,</span></div><div class="line"><a name="l00182"></a><span class="lineno">  182</span>&#160;<span class="comment">                          * 6a, 6c, 6f, 71, 72, 74, 77, 78, 7b, 7d, 7e, 81, 82, 84, 87, 88, 8b, 8d, 8e,</span></div><div class="line"><a name="l00183"></a><span class="lineno">  183</span>&#160;<span class="comment">                          * 90, 93, 95, 96, 99, 9a, 9c, 9f, a0, a3, a5, a6, a9, aa, ac, af, b1, b2, b4,</span></div><div class="line"><a name="l00184"></a><span class="lineno">  184</span>&#160;<span class="comment">                          * b7, b8, bb, bd, be</span></div><div class="line"><a name="l00185"></a><span class="lineno">  185</span>&#160;<span class="comment">                          *</span></div><div class="line"><a name="l00186"></a><span class="lineno">  186</span>&#160;<span class="comment">                          * Custom values: f0, f3, f5, f6, f9, fa, fc, ff</span></div><div class="line"><a name="l00187"></a><span class="lineno">  187</span>&#160;<span class="comment">                          */</span><span class="preprocessor"></span></div><div class="line"><a name="l00188"></a><span class="lineno">  188</span>&#160;</div><div class="line"><a name="l00192"></a><span class="lineno">  192</span>&#160;<span class="preprocessor">#define HAB_MAJOR_VERSION 4 </span></div><div class="line"><a name="l00193"></a><span class="lineno">  193</span>&#160;<span class="preprocessor">#define HAB_MINOR_VERSION 0 </span></div><div class="line"><a name="l00194"></a><span class="lineno">  194</span>&#160;<span class="preprocessor">#define HAB_VER_MAJ_WIDTH 4 </span></div><div class="line"><a name="l00195"></a><span class="lineno">  195</span>&#160;<span class="preprocessor">#define HAB_VER_MAJ_SHIFT 4 </span></div><div class="line"><a name="l00196"></a><span class="lineno">  196</span>&#160;<span class="preprocessor">#define HAB_VER_MIN_WIDTH 4 </span></div><div class="line"><a name="l00197"></a><span class="lineno">  197</span>&#160;<span class="preprocessor">#define HAB_VER_MIN_SHIFT 0 </span></div><div class="line"><a name="l00199"></a><span class="lineno">  199</span>&#160;<span class="preprocessor">#define HAB_VERSION HAB_VER(HAB_MAJOR_VERSION, HAB_MINOR_VERSION)</span></div><div class="line"><a name="l00200"></a><span class="lineno">  200</span>&#160;</div><div class="line"><a name="l00201"></a><span class="lineno">  201</span>&#160;<span class="preprocessor">#define HAB_BASE_VERSION HAB_VER(HAB_MAJOR_VERSION, 0)</span></div><div class="line"><a name="l00202"></a><span class="lineno">  202</span>&#160;</div><div class="line"><a name="l00205"></a><span class="lineno">  205</span>&#160;<span class="keyword">namespace </span><a class="code" href="namespaceelftosb.html">elftosb</a></div><div class="line"><a name="l00206"></a><span class="lineno">  206</span>&#160;{</div><div class="line"><a name="l00220"></a><span class="lineno"><a class="line" href="classelftosb_1_1_i_v_t_data_source.html">  220</a></span>&#160;<span class="keyword">class </span><a class="code" href="classelftosb_1_1_i_v_t_data_source.html">IVTDataSource</a> : <span class="keyword">public</span> <a class="code" href="classelftosb_1_1_data_source.html">DataSource</a>, <span class="keyword">public</span> <a class="code" href="classelftosb_1_1_data_source_1_1_segment.html">DataSource::Segment</a></div><div class="line"><a name="l00221"></a><span class="lineno">  221</span>&#160;{</div><div class="line"><a name="l00222"></a><span class="lineno">  222</span>&#160;<span class="keyword">public</span>:</div><div class="line"><a name="l00224"></a><span class="lineno">  224</span>&#160;    <a class="code" href="classelftosb_1_1_i_v_t_data_source.html">IVTDataSource</a>();</div><div class="line"><a name="l00225"></a><span class="lineno">  225</span>&#160;</div><div class="line"><a name="l00227"></a><span class="lineno"><a class="line" href="classelftosb_1_1_i_v_t_data_source.html#a49da47350d8f28f21f9df4c885714499">  227</a></span>&#160;    <span class="keyword">virtual</span> <span class="keywordtype">unsigned</span> <a class="code" href="classelftosb_1_1_i_v_t_data_source.html#a49da47350d8f28f21f9df4c885714499">getSegmentCount</a>() { <span class="keywordflow">return</span> 1; }</div><div class="line"><a name="l00229"></a><span class="lineno"><a class="line" href="classelftosb_1_1_i_v_t_data_source.html#ab489130aa85f8bfb52ca076730bf2cec">  229</a></span>&#160;    <span class="keyword">virtual</span> <a class="code" href="classelftosb_1_1_data_source_1_1_segment.html">DataSource::Segment</a> *<a class="code" href="classelftosb_1_1_i_v_t_data_source.html#ab489130aa85f8bfb52ca076730bf2cec">getSegmentAt</a>(<span class="keywordtype">unsigned</span> index) { <span class="keywordflow">return</span> <span class="keyword">this</span>; }</div><div class="line"><a name="l00231"></a><span class="lineno">  231</span>&#160;</div><div class="line"><a name="l00232"></a><span class="lineno">  232</span>&#160;</div><div class="line"><a name="l00235"></a><span class="lineno">  235</span>&#160;    <span class="keyword">virtual</span> <span class="keywordtype">unsigned</span> getData(<span class="keywordtype">unsigned</span> offset, <span class="keywordtype">unsigned</span> maxBytes, uint8_t *buffer);</div><div class="line"><a name="l00236"></a><span class="lineno">  236</span>&#160;</div><div class="line"><a name="l00238"></a><span class="lineno">  238</span>&#160;    <span class="keyword">virtual</span> <span class="keywordtype">unsigned</span> getLength();</div><div class="line"><a name="l00239"></a><span class="lineno">  239</span>&#160;</div><div class="line"><a name="l00241"></a><span class="lineno">  241</span>&#160;    <span class="keyword">virtual</span> <span class="keywordtype">bool</span> hasNaturalLocation();</div><div class="line"><a name="l00242"></a><span class="lineno">  242</span>&#160;</div><div class="line"><a name="l00244"></a><span class="lineno">  244</span>&#160;    <span class="keyword">virtual</span> uint32_t getBaseAddress();</div><div class="line"><a name="l00245"></a><span class="lineno">  245</span>&#160;</div><div class="line"><a name="l00247"></a><span class="lineno">  247</span>&#160;</div><div class="line"><a name="l00249"></a><span class="lineno">  249</span>&#160;</div><div class="line"><a name="l00250"></a><span class="lineno">  250</span>&#160;</div><div class="line"><a name="l00272"></a><span class="lineno">  272</span>&#160;    <span class="keywordtype">bool</span> setFieldByName(<span class="keyword">const</span> std::string &amp;name, uint32_t value);</div><div class="line"><a name="l00273"></a><span class="lineno">  273</span>&#160;</div><div class="line"><a name="l00275"></a><span class="lineno"><a class="line" href="classelftosb_1_1_i_v_t_data_source.html#a48b8edef123cc272bbddb10b3e8fd5f5">  275</a></span>&#160;    hab_ivt_t &amp;<a class="code" href="classelftosb_1_1_i_v_t_data_source.html#a48b8edef123cc272bbddb10b3e8fd5f5">getIVT</a>() { <span class="keywordflow">return</span> m_ivt; }</div><div class="line"><a name="l00277"></a><span class="lineno">  277</span>&#160;</div><div class="line"><a name="l00278"></a><span class="lineno">  278</span>&#160;<span class="keyword">protected</span>:</div><div class="line"><a name="l00279"></a><span class="lineno"><a class="line" href="classelftosb_1_1_i_v_t_data_source.html#acd57f2561051ffeb18273ce71d4aa1ba">  279</a></span>&#160;    hab_ivt_t <a class="code" href="classelftosb_1_1_i_v_t_data_source.html#acd57f2561051ffeb18273ce71d4aa1ba">m_ivt</a>;  </div><div class="line"><a name="l00280"></a><span class="lineno"><a class="line" href="classelftosb_1_1_i_v_t_data_source.html#a7fbac73d0ceead9c4f4a585fb084ca99">  280</a></span>&#160;    <span class="keywordtype">bool</span> <a class="code" href="classelftosb_1_1_i_v_t_data_source.html#a7fbac73d0ceead9c4f4a585fb084ca99">m_isSelfSet</a>; </div><div class="line"><a name="l00281"></a><span class="lineno">  281</span>&#160;};</div><div class="line"><a name="l00282"></a><span class="lineno">  282</span>&#160;</div><div class="line"><a name="l00283"></a><span class="lineno">  283</span>&#160;} <span class="comment">// elftosb</span></div><div class="line"><a name="l00284"></a><span class="lineno">  284</span>&#160;</div><div class="line"><a name="l00285"></a><span class="lineno">  285</span>&#160;<span class="preprocessor">#endif // _IVTDataSource_h_</span></div><div class="ttc" id="structhab__ivt_html_a1b7fc9e9d52309f56b57a9543349bf00"><div class="ttname"><a href="structhab__ivt.html#a1b7fc9e9d52309f56b57a9543349bf00">hab_ivt::hdr</a></div><div class="ttdeci">hab_hdr_t hdr</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:96</div></div>
<div class="ttc" id="classelftosb_1_1_data_source_html"><div class="ttname"><a href="classelftosb_1_1_data_source.html">elftosb::DataSource</a></div><div class="ttdoc">Abstract base class for data sources. </div><div class="ttdef"><b>Definition:</b> apps/elftosb/common/DataSource.h:33</div></div>
<div class="ttc" id="structhab__hdr__t_html"><div class="ttname"><a href="structhab__hdr__t.html">hab_hdr_t</a></div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:23</div></div>
<div class="ttc" id="classelftosb_1_1_i_v_t_data_source_html_ab489130aa85f8bfb52ca076730bf2cec"><div class="ttname"><a href="classelftosb_1_1_i_v_t_data_source.html#ab489130aa85f8bfb52ca076730bf2cec">elftosb::IVTDataSource::getSegmentAt</a></div><div class="ttdeci">virtual DataSource::Segment * getSegmentAt(unsigned index)</div><div class="ttdoc">Returns this object, as it is its own segment. </div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:229</div></div>
<div class="ttc" id="structhab__ivt_html_afc055b3b0f6aa49f14f48333bf331982"><div class="ttname"><a href="structhab__ivt.html#afc055b3b0f6aa49f14f48333bf331982">hab_ivt::entry</a></div><div class="ttdeci">uint32_t entry</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:100</div></div>
<div class="ttc" id="classelftosb_1_1_i_v_t_data_source_html_a7fbac73d0ceead9c4f4a585fb084ca99"><div class="ttname"><a href="classelftosb_1_1_i_v_t_data_source.html#a7fbac73d0ceead9c4f4a585fb084ca99">elftosb::IVTDataSource::m_isSelfSet</a></div><div class="ttdeci">bool m_isSelfSet</div><div class="ttdoc">True if the IVT self pointer was explicitly set. </div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:280</div></div>
<div class="ttc" id="structhab__ivt_html_af15467ad5c571cb1989439c412b85a71"><div class="ttname"><a href="structhab__ivt.html#af15467ad5c571cb1989439c412b85a71">hab_ivt::dcd</a></div><div class="ttdeci">uint32_t dcd</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:104</div></div>
<div class="ttc" id="structhab__ivt_html_ad7d705aa6b9f376da4b45dc2aee99112"><div class="ttname"><a href="structhab__ivt.html#ad7d705aa6b9f376da4b45dc2aee99112">hab_ivt::boot_data</a></div><div class="ttdeci">uint32_t boot_data</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:108</div></div>
<div class="ttc" id="structhab__hdr__t_html_aa93cdf5874f6a16f0d84e7a0eaaf43d9"><div class="ttname"><a href="structhab__hdr__t.html#aa93cdf5874f6a16f0d84e7a0eaaf43d9">hab_hdr_t::par</a></div><div class="ttdeci">uint8_t par</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:27</div></div>
<div class="ttc" id="classelftosb_1_1_i_v_t_data_source_html"><div class="ttname"><a href="classelftosb_1_1_i_v_t_data_source.html">elftosb::IVTDataSource</a></div><div class="ttdoc">Data source for an IVT structure used by HAB4. </div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:220</div></div>
<div class="ttc" id="namespaceelftosb_html"><div class="ttname"><a href="namespaceelftosb.html">elftosb</a></div><div class="ttdef"><b>Definition:</b> BootImage.h:13</div></div>
<div class="ttc" id="structhab__ivt_html_a117eb7ff63a99d084b07d2fcce5ff1f1"><div class="ttname"><a href="structhab__ivt.html#a117eb7ff63a99d084b07d2fcce5ff1f1">hab_ivt::csf</a></div><div class="ttdeci">uint32_t csf</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:112</div></div>
<div class="ttc" id="classelftosb_1_1_i_v_t_data_source_html_a48b8edef123cc272bbddb10b3e8fd5f5"><div class="ttname"><a href="classelftosb_1_1_i_v_t_data_source.html#a48b8edef123cc272bbddb10b3e8fd5f5">elftosb::IVTDataSource::getIVT</a></div><div class="ttdeci">hab_ivt_t &amp; getIVT()</div><div class="ttdoc">Returns a reference to the IVT structure. </div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:275</div></div>
<div class="ttc" id="structhab__ivt_html"><div class="ttname"><a href="structhab__ivt.html">hab_ivt</a></div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:91</div></div>
<div class="ttc" id="classelftosb_1_1_data_source_1_1_segment_html"><div class="ttname"><a href="classelftosb_1_1_data_source_1_1_segment.html">elftosb::DataSource::Segment</a></div><div class="ttdoc">Discrete, contiguous part of the source&amp;#39;s data. </div><div class="ttdef"><b>Definition:</b> apps/elftosb/common/DataSource.h:42</div></div>
<div class="ttc" id="classelftosb_1_1_i_v_t_data_source_html_a49da47350d8f28f21f9df4c885714499"><div class="ttname"><a href="classelftosb_1_1_i_v_t_data_source.html#a49da47350d8f28f21f9df4c885714499">elftosb::IVTDataSource::getSegmentCount</a></div><div class="ttdeci">virtual unsigned getSegmentCount()</div><div class="ttdoc">There is only one segment. </div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:227</div></div>
<div class="ttc" id="structhab__ivt_html_a6b496edf283c9d3b3b2397e6fd4a8db7"><div class="ttname"><a href="structhab__ivt.html#a6b496edf283c9d3b3b2397e6fd4a8db7">hab_ivt::reserved1</a></div><div class="ttdeci">uint32_t reserved1</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:102</div></div>
<div class="ttc" id="classelftosb_1_1_i_v_t_data_source_html_acd57f2561051ffeb18273ce71d4aa1ba"><div class="ttname"><a href="classelftosb_1_1_i_v_t_data_source.html#acd57f2561051ffeb18273ce71d4aa1ba">elftosb::IVTDataSource::m_ivt</a></div><div class="ttdeci">hab_ivt_t m_ivt</div><div class="ttdoc">The IVT structure. </div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:279</div></div>
<div class="ttc" id="structhab__hdr__t_html_ad7913394bcc1cc055f23c71d6a8cf875"><div class="ttname"><a href="structhab__hdr__t.html#ad7913394bcc1cc055f23c71d6a8cf875">hab_hdr_t::tag</a></div><div class="ttdeci">uint8_t tag</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:25</div></div>
<div class="ttc" id="structhab__ivt_html_a2c8ce15b7dd410f382d19515d51d471e"><div class="ttname"><a href="structhab__ivt.html#a2c8ce15b7dd410f382d19515d51d471e">hab_ivt::reserved2</a></div><div class="ttdeci">uint32_t reserved2</div><div class="ttdef"><b>Definition:</b> IVTDataSource.h:114</div></div>
</div><!-- fragment --></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_96c2f84c885cff71a930b6845f88cdd3.html">elftosb</a></li><li class="navelem"><a class="el" href="dir_c476059e18722267e10e2fb2cca6f785.html">common</a></li><li class="navelem"><b>IVTDataSource.h</b></li>
    <li class="footer">Generated on Mon Mar 7 2016 16:49:50 for Kinetis Bootloader Host by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.11 </li>
  </ul>
</div>
</body>
</html>
